home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Ubuntu 9.10 PL / karmelkowy-koliberek-9.10-netbook-remix-PL.iso / casper / filesystem.squashfs / etc / init.d / .umountroot.swp (.txt) < prev    next >
Vim Swap  |  2009-10-14  |  12KB  |  52 lines

  1. b0VIM 7.2
  2. scott
  3. warcraft
  4. ~scott/work/native-upstart/sysvinit-2.87dsf/debian/initscripts/etc/init.d/umountroot
  5.     exit 3
  6.     echo "Usage: $0 start|stop" >&2
  7.     do_stop
  8.   stop)
  9.     exit 3
  10.     echo "Error: argument '$1' not supported" >&2
  11.   restart|reload|force-reload)
  12.     # No-op
  13.   start)
  14. case "$1" in
  15.     [ "$VERBOSE" = no ] || log_action_end_msg $ES
  16.     ES=$?
  17.     || mount $MOUNT_FORCE_OPT -n -o remount,ro                       /
  18.     || mount $MOUNT_FORCE_OPT -n -o remount,ro              dummydev / 2>/dev/null \
  19.     mount    $MOUNT_FORCE_OPT -n -o remount,ro -t dummytype dummydev / 2>/dev/null \
  20.     # See #339023 and the comment in checkroot.sh
  21.     # will act on a bind mount of / if there is one.
  22.     #     mount -n -o remount,ro /
  23.     # This:
  24.     [ "$(uname -s)" = "GNU/kFreeBSD" ] && MOUNT_FORCE_OPT=-f
  25.     MOUNT_FORCE_OPT=
  26.     [ -f /var/run/init.upgraded ] && telinit u || :
  27.     # it won't hold open files on the root filesystem
  28.     # upgraded this cycle.  It'll lose all its state, but at least
  29.     # Ask init to reexec itself before we go down if it has been
  30.     done
  31.         mkdir -p $dir || true
  32.     for dir in /proc /sys /var/run /var/lock; do
  33.     # mount point exists) or we can make the mountpoint.
  34.     # filesystems, so either they are mounted now (in which case the
  35.     # targets for system mountpoints.  We've just unmounted all other
  36.     # These directories must exist on the root filesystem as they are
  37.     [ "$VERBOSE" = no ] || log_action_begin_msg "Mounting root filesystem read-only"
  38. do_stop () {
  39. . /lib/lsb/init-functions
  40. . /lib/init/vars.sh
  41. PATH=/sbin:/bin
  42. ### END INIT INFO
  43. # Short-Description: Mount the root filesystem read-only.
  44. # Default-Stop:      0 6
  45. # Default-Start:
  46. # Should-Stop:       halt reboot kexec
  47. # Required-Stop:
  48. # Required-Start:
  49. # Provides:          umountroot
  50. ### BEGIN INIT INFO
  51. #! /bin/sh
  52.